package model

import (
	"time"
)

type StatisticsArticlePV struct {
	ID         uint64    `gorm:"primaryKey;autoIncrement;comment:'id'" json:"id"`
	PvDate     time.Time `gorm:"type:date;not null;unique;comment:'被统计的日期'" json:"pv_date"`
	PvCount    uint64    `gorm:"type:bigint unsigned;not null;comment:'pv访问量'" json:"pv_count"`
	CreateTime time.Time `gorm:"type:datetime;not null;default:CURRENT_TIMESTAMP;comment:'创建时间'" json:"create_time"`
	UpdateTime time.Time `gorm:"type:datetime;not null;default:CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP;comment:'最后一次更新时间'" json:"update_time"`
}

func (StatisticsArticlePV) TableName() string {
	return "t_statistics_article_pv"
}
